package com.company;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @date : 2021/12/21 13:06
 * jdk格式化时间问题
 * https://zhuanlan.zhihu.com/p/89914219
 */

public class P013_SimpleDateFormat {
    public static void main(String[] args) {
        try {
            SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
            Date date = simpleDateFormat.parse("1900-01-01 08:00:00");
            System.out.println(simpleDateFormat.format(date));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
